<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>Vue中的条件渲染</title>
		<script type="text/javascript" src="js/vue.js" ></script>
	</head>
	<body>
		<div id="app">
			<div v-if="show">
				用户名：<input key="username" />
			</div>
			<div v-else>
				邮箱名：<input key="mailname"/>
			</div>
		</div>
		<script>
			var vm = new Vue({
				el: "#app",
				data: {
					show: false
				}
			})
		</script>
	</body>
</html>
